Constrained Type Families (extended version)
نویسندگان
چکیده
We present an approach to support partiality in type-level computation without compromising expressiveness or type safety. Existing frameworks for type-level computation either require totality or implicitly assume it. For example, type families in Haskell provide a powerful, modular means of dening type-level computation. However, their current design implicitly assumes that type families are total, introducing nonsensical types and signicantly complicating the metatheory of type families and their extensions. We propose an alternative design, using qualied types to pair type-level computations with predicates that capture their domains. Our approach naturally captures the intuitive partiality of type families, simplifying their metatheory. As evidence, we present the rst complete proof of consistency for a language with closed type families.
منابع مشابه
Constrained Type Families (extended version), preprint
We present an approach to support partiality in type-level computation without compromising expressiveness or type safety. Existing frameworks for type-level computation either require totality or implicitly assume it. For example, type families in Haskell provide a powerful, modular means of dening type-level computation. However, their current design implicitly assumes that type families are...
متن کاملAdapting a specialized ADHD parenting programme for use with hard to reach and difficult to treat preschool children
Adapting a specialized ADHD parenting programme for use with 'hard to reach' and 'difficult to treat' preschool children. This version is made available in accordance with publisher policies. Please cite only the published version using the reference above. Background: Effective implementation of parent training programmes for preschool Attention-Deficit/Hyper-activity Disorder type is constrai...
متن کاملA pathogenic variant in the transforming growth factor beta I (TGFBI) in four Iranian extended families segregating granular corneal dystrophy type II: A literature review
Objective(s): Granular and lattice corneal dystrophies (GCDs & LCDs) are autosomal dominant inherited disorders of the cornea. Due to genetic heterogeneity and large genes, unraveling the mutation is challenging.Materials and Methods: Patients underwent comprehensive clinical examination, and targeted next-generation sequencing (NGS) was...
متن کاملAn overabundance of equality : Implementing kind equalities into Haskell ( Extended version )
Haskell, as embodied by version 7.10.1 of the Glasgow Haskell Compiler (GHC), supports reasoning about equality among types, via generalized algebraic datatypes (GADTs) and type families. However, these features are not available among the kinds that classify the types. Motivated by a concrete example of how kind equalities can help programmers today, this paper presents the challenges and solu...
متن کاملJavaGI : Generalized Interfaces for Java
JavaGI is an experimental language that extends Java 1.5 by generalizing the interface concept to incorporate the essential features of Haskell’s type classes. In particular, generalized interfaces cater for retroactive and constrained interface implementations, binary methods, static methods in interfaces, default implementations for interface methods, interfaces over families of types, and ex...
متن کاملذخیره در منابع من
با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید
عنوان ژورنال:
دوره شماره
صفحات -
تاریخ انتشار 2017